import { createRouter, createWebHistory } from 'vue-router'
import Layout from '@/views/Layout.vue'
import Index from '@/views/Index.vue'

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path:'/layout',
      component:Layout  ,
      children:[
        {
          path:'index',
          component:Index
        },
      ]
    },
    {
      path:'/',
      redirect:'/layout'
    }
  ]
})

export default router
